package com.aloda.ojcommon.anno;

import com.aloda.ojcommon.domain.enums.UserRoleEnum;

import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
 * 权限校验注解，用户调用注解方法必须拥有注解对应权限，否则返回无权限错误
 * @Author aloda
 * @Date 2025/4/27 10:15
 */
@Target(ElementType.METHOD)
@Retention(RetentionPolicy.RUNTIME)
public @interface AuthCheck {

    UserRoleEnum[] role();
}
